package edu.gatech.spacetraderteam3.model;

import java.util.List;


/**
 * Encounters between the player and pirates, police, traders and nothing
 * @author TBW
 * @version 1.0
 */
public class Encounter {
    
	/**
	 * The string that describes the encounter
	 */
	private final String displayString;
    
	/**
	 * The List of appropriate actions for this encounter
	 */
	private final List<EncounterAction> actionList;
    
	/**
	 * The Actor that the player has encountered
	 */
	private final Actor other;

	/**
	 * Sets up the encounter
	 * @param displayString
	 * @param actions
	 * @param other
	 */
    public Encounter(String displayString, List<EncounterAction> actions, Actor other) {
        this.displayString = displayString;
        this.actionList = actions;
        this.other = other;
    }
    
    /**
     * Getter for the displayString
     * @return the displayString
     */
    public String getDisplayString() {
        return this.displayString;
    }

    /**
     * Getter for the list of actions
     * @return the list of actions
     */
    public List<EncounterAction> getActionList() {
        return this.actionList;
    }

    /**
     * Getter for the encountered Actor
     * @return the encountered Actor
     */
    public Actor getActor() {
        return this.other;
    }
    
    /**
     * This class's toString method
     * @return the string representation of this class
     */
    public String toString(){
    	return "Encounter with " + other.toString() + " with message: " + displayString;
    }
}
